.PHONY:all
all:server client

server:main.cc
	g++ -o $@ $^ -std=c++17 -ljsoncpp -lpthread -static
client:TcpClient.cc
	g++ -o $@ $^ -std=c++17 -ljsoncpp -lpthread -static

.PHONY:clean
clean:
	rm -rf server client

.PHONY:output
output:
	@mkdir -p output
	@mkdir -p output/conf
	@mkdir -p output/bin
	@mkdir -p output/log
	@cp server output/bin
	@cp client output/bin
	@cp install.sh output
	@cp uninstall.sh output
	@cp test.conf output/conf
	@tar czf output.tgz output